<!DOCTYPE html>
<!-- saved from url=(0109)https://yingfang-1254029722.cos.ap-chengdu.myqcloud.com/100%E4%BB%A5%E5%86%85%E5%8A%A0%E5%87%8F%E6%B3%95.html -->
<html><head><meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
		
		<title>二十以内加减法</title>
		<style>
			.parent {
				text-align: center;
			}

			.child1 {
				float: center;
				width: 100%;
				height: 30px;
				display: inline-block;
			}

			.child2 {
				float: center;
				width: 600px;
				height: 100%;
				display: inline-block;
			}

			.child3 {
				float: left;
				width: 25%;
				height: 100%;
				background: white;
			}
		</style>
	</head>
	<body>
		<h1 style="text-align: center;">100道二十以内加减法</h1>
		<h3 style="text-align: center;">廖尘疏</h3>
		<h4 style="text-align: right;" id="timeRight"></h4>
		<div class="parent"><div class="child1"><div class="child2"><div class="child3"><span>93 + 36 = ___</span></div><div class="child3"><span>68 + 44 = ___</span></div><div class="child3"><span>84 - 72 = ___</span></div><div class="child3"><span>16 + 23 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>87 - 28 = ___</span></div><div class="child3"><span>89 - 68 = ___</span></div><div class="child3"><span>95 - 46 = ___</span></div><div class="child3"><span>31 + 87 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>79 - 42 = ___</span></div><div class="child3"><span>92 - 56 = ___</span></div><div class="child3"><span>63 - 53 = ___</span></div><div class="child3"><span>83 + 93 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>65 - 39 = ___</span></div><div class="child3"><span>87 - 35 = ___</span></div><div class="child3"><span>98 - 95 = ___</span></div><div class="child3"><span>36 + 63 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>81 + 50 = ___</span></div><div class="child3"><span>51 + 44 = ___</span></div><div class="child3"><span>69 + 12 = ___</span></div><div class="child3"><span>38 + 59 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>90 + 56 = ___</span></div><div class="child3"><span>99 - 38 = ___</span></div><div class="child3"><span>75 + 20 = ___</span></div><div class="child3"><span>70 - 32 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>72 + 61 = ___</span></div><div class="child3"><span>95 - 93 = ___</span></div><div class="child3"><span>95 + 93 = ___</span></div><div class="child3"><span>55 - 48 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>93 - 69 = ___</span></div><div class="child3"><span>71 - 21 = ___</span></div><div class="child3"><span>31 + 60 = ___</span></div><div class="child3"><span>92 - 40 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>12 + 20 = ___</span></div><div class="child3"><span>34 - 30 = ___</span></div><div class="child3"><span>83 - 65 = ___</span></div><div class="child3"><span>96 - 71 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>93 + 14 = ___</span></div><div class="child3"><span>98 - 83 = ___</span></div><div class="child3"><span>63 - 38 = ___</span></div><div class="child3"><span>99 - 98 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>29 + 65 = ___</span></div><div class="child3"><span>95 - 90 = ___</span></div><div class="child3"><span>81 - 56 = ___</span></div><div class="child3"><span>74 - 37 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>65 - 63 = ___</span></div><div class="child3"><span>41 - 22 = ___</span></div><div class="child3"><span>68 - 58 = ___</span></div><div class="child3"><span>76 - 64 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>22 + 82 = ___</span></div><div class="child3"><span>73 + 40 = ___</span></div><div class="child3"><span>37 + 31 = ___</span></div><div class="child3"><span>63 + 72 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>86 - 76 = ___</span></div><div class="child3"><span>46 - 30 = ___</span></div><div class="child3"><span>95 - 87 = ___</span></div><div class="child3"><span>61 - 41 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>26 + 51 = ___</span></div><div class="child3"><span>59 + 62 = ___</span></div><div class="child3"><span>82 + 94 = ___</span></div><div class="child3"><span>48 - 31 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>73 + 30 = ___</span></div><div class="child3"><span>43 + 11 = ___</span></div><div class="child3"><span>21 + 81 = ___</span></div><div class="child3"><span>21 + 54 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>38 - 17 = ___</span></div><div class="child3"><span>63 + 97 = ___</span></div><div class="child3"><span>96 - 69 = ___</span></div><div class="child3"><span>96 + 92 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>65 + 88 = ___</span></div><div class="child3"><span>81 - 75 = ___</span></div><div class="child3"><span>40 - 14 = ___</span></div><div class="child3"><span>64 + 14 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>63 - 25 = ___</span></div><div class="child3"><span>89 - 77 = ___</span></div><div class="child3"><span>44 + 60 = ___</span></div><div class="child3"><span>71 + 51 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>62 - 55 = ___</span></div><div class="child3"><span>51 + 80 = ___</span></div><div class="child3"><span>63 + 84 = ___</span></div><div class="child3"><span>90 + 44 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>20 + 67 = ___</span></div><div class="child3"><span>78 - 63 = ___</span></div><div class="child3"><span>96 + 20 = ___</span></div><div class="child3"><span>28 + 66 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>75 + 80 = ___</span></div><div class="child3"><span>98 + 18 = ___</span></div><div class="child3"><span>62 + 18 = ___</span></div><div class="child3"><span>77 + 67 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>97 + 40 = ___</span></div><div class="child3"><span>68 + 57 = ___</span></div><div class="child3"><span>97 - 44 = ___</span></div><div class="child3"><span>98 - 69 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>68 + 28 = ___</span></div><div class="child3"><span>65 - 31 = ___</span></div><div class="child3"><span>94 - 89 = ___</span></div><div class="child3"><span>34 + 65 = ___</span></div></div></div><div class="child1"><div class="child2"><div class="child3"><span>84 - 37 = ___</span></div><div class="child3"><span>30 + 59 = ___</span></div><div class="child3"><span>33 + 74 = ___</span></div><div class="child3"><span>92 - 76 = ___</span></div></div></div></div>
		<script>
			init();

			function init() {
				var date = new Date();
				this.year = date.getFullYear();
				this.month = date.getMonth() + 1;
				this.date = date.getDate();
				this.day = new Array("星期日", "星期一", "星期二", "星期三", "星期四", "星期五", "星期六")[date.getDay()];
				this.hour = date.getHours() < 10 ? "0" + date.getHours() : date.getHours();
				this.minute = date.getMinutes() < 10 ? "0" + date.getMinutes() : date.getMinutes();
				this.second = date.getSeconds() < 10 ? "0" + date.getSeconds() : date.getSeconds();
				var currentTime = this.year + "年" + this.month + "月" + this.date + "日 "
					//+ this.hour + ":" + this.minute + ":" + this.second 
					+ " " + this.day;
				var timeRight = document.getElementById("timeRight");
				timeRight.innerHTML = currentTime;

				var parent = document.getElementsByClassName("parent")[0];
				var html = '';
				var str1 = '<div class="child1"><div class="child2">';
				var str2 = '<div class="child3"><span>';
				var str3 = '</span></div>';
				var str4 = '</div></div>';
				for (var i = 0; i < 25; i++) {
					html += str1;
					for (var j = 0; j < 4; j++) {
						var nodeHtml = getCalc();
						html += str2;
						html += nodeHtml;
						html += str3;
					}
					html += str4;
				}
				parent.innerHTML = html;
			}

			function getCalc() {
				var isAdd = randomNum(0, 1);
				if (isAdd) {
					//加法
					var a1 = randomNum(1, 19);
					var tmp = randomNum(a1 + 1, 20);
					var a2 = tmp - a1;
					return '' + a1 + ' + ' + a2 + ' = ___';
				} else {
					//减法
					var a1 = randomNum(2, 20);
					var a2 = randomNum(1, a1 - 1);
					return '' + a1 + ' - ' + a2 + ' = ___';
				}
			}

			function randomNum(minNum, maxNum) {
				switch (arguments.length) {
					case 1:
						return parseInt(Math.random() * minNum + 1, 10);
						break;
					case 2:
						return parseInt(Math.random() * (maxNum - minNum + 1) + minNum, 10);
						break;
					default:
						return 0;
						break;
				}
			}
		</script>
	

</body></html>